package com.xysq.widget;

import android.content.Context;
import android.graphics.Color;
import android.view.View;

import com.flyco.dialog.utils.CornerUtils;
import com.flyco.dialog.widget.base.BaseDialog;

/**
 * Created by Steward_Han on 2015/9/23.
 */
public class EditDialog extends BaseDialog {
    private View view;

    public EditDialog(Context context, View view) {
        super(context);
        this.view = view;
    }

    @Override
    public View onCreateView() {
        widthScale(0.85f);
        view.setBackgroundDrawable(
                CornerUtils.cornerDrawable(Color.parseColor("#ffffff"), dp2px(5)));
        setCanceledOnTouchOutside(false);
        return view;
    }

    /**
     * set Ui data or logic opreation before attatched window(在对话框显示之前,设置界面数据或者逻辑)
     *
     * @return true dialog show,fasle dialog not show
     */
    @Override
    public boolean setUiBeforShow() {
        return false;
    }
}